﻿{extend name="public:base" /}

{block name="content"}
<div class="wrapper wrapper-content animated fadeInRight">
    <div class="row">
        <div class="col-lg-12">
            <div class="ibox ">
                <div class="ibox-title">
                    <div class="ibox-tools">
                        <a class="collapse-link">
                            <i class="fa fa-chevron-up"></i>
                        </a>
                    </div>
                </div>

                <div class="ibox-content">
                    <div class="row search-form">
                        <div class="col-sm-2 m-b-sm">
                            <div class="input-group">
                                <select name="status" class="form-control form-control-lg">
                                    <option value="-1">请选择审核状态</option>
                                    <option value="0" {:input(
                                    'status') === '0' ? 'selected' : ''}>待审核</option>
                                    <option value="1" {:input(
                                    'status') == 1 ? 'selected' : ''}>审核成功</option>
                                    <option value="2" {:input(
                                    'status') == 2 ? 'selected' : ''}>审核失败</option>
                                </select>
                            </div>
                        </div>
                        <div class="col-sm-2 m-b-sm">
                            <div class="input-group">
                                <button type="button" class="btn btn-primary btn-lg screen-btn">搜索</button>
                            </div>
                        </div>
                    </div>
                    <div class="table-responsive">
                        <table class="table table-striped">
                            <thead>
                            <tr>
                                <th>ID</th>
                                <th>用户</th>
                                <th>手机号</th>
                                <th>门店名称</th>
                                <th>门店地址</th>
                                <th>门店状态</th>
                                <th>审核状态</th>
                                <th>审核通过时间</th>
                                <th>申请审核时间</th>
                                <th>操作</th>
                            </tr>
                            </thead>
                            <tbody>
                            {volist name="list" id="vo"}
                            <tr>
                                <td>{$vo.id}</td>
                                <td>{$vo.username}</td>
                                <td>{$vo.mobile}</td>
                                <td>{$vo.name}</td>
                                <td>{$vo.province}-{$vo.city}-{$vo.area}</td>
                                <td>{$vo.disable == 1 ? '启用' : '禁用'}</td>
                                <td>{$vo.status_desc}</td>
                                <td>{:timeFormat($vo.success_time)}</td>
                                <td>{:timeFormat($vo.create_time)}</td>
                                <td class="project-actions">
                                    {if $vo.status == 1}
                                    {if $vo.disable == 1}
                                    <a href="{:url('doDisable', ['id' => $vo.id, 'disable' => -1])}" class="btn btn-white btn-sm ajax-operate">
                                        <i class="fa fa-close"></i> 禁用
                                    </a>
                                    {else /}
                                    <a href="{:url('doDisable', ['id' => $vo.id, 'disable' => 1])}" class="btn btn-white btn-sm ajax-operate">
                                        <i class="fa fa-check"></i> 启用
                                    </a>
                                    {/if}
                                    {/if}
                                    <a href="{:url('doShop', ['id' => $vo.id])}" class="btn btn-white btn-sm">
                                        <i class="fa fa-edit"></i> 查看详情
                                    </a>
                                </td>
                            </tr>
                            {/volist}
                            </tbody>
                        </table>
                        {if !empty($list->items())}{$list->render()}{/if}
                    </div>

                </div>
            </div>
        </div>

    </div>
</div>

{/block}

